package com.lkd.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.lkd.dao.TaskDetailsDao;
import com.lkd.entity.TaskDetailsEntity;
import com.lkd.service.TaskDetailsService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TaskDetailsServiceImpl extends ServiceImpl<TaskDetailsDao, TaskDetailsEntity> implements TaskDetailsService {

    /**
     * 根据工单id查询补货详情
     *
     * @param taskId
     * @return
     */
    @Override
    public List<TaskDetailsEntity> getTaskDetailList(Long taskId) {

        LambdaQueryWrapper<TaskDetailsEntity> queryWrapper = new LambdaQueryWrapper<>();
        queryWrapper.eq(TaskDetailsEntity::getTaskId, taskId);
        return this.list(queryWrapper);

    }
}
